<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <title>Document</title>
  <style>
   .overlay{
    position: absolute;
    inset: 0;
    background-color:rgba(0, 0, 0, 0.3);
   }
    
  </style>
</head>
<body>
  <input type="text">
  <div class="overlay"></div>
</body>
</html>